package com.imddysc.spbbatchitemprocessor;

import org.springframework.batch.item.ItemProcessor;
import org.springframework.stereotype.Component;

@Component("idFilterProcessor")
public class IdFilterProcessor implements ItemProcessor<Customer, Customer> {

	@Override
	public Customer process(Customer customer) throws Exception {
        if(customer.getId()%2==0) {
        	return customer;        	
        }
        else {
        	return null;        	
        }
    }
}
